import uuid
if __name__ == '__main__':

    aa = 0
    while (True):
        uuid_ = uuid.uuid1()

        str = input("请输入：");
        if (float(str) == 0):
            exit(0)
        if ((float(str) % 3) > 0):
            aa = aa + float(str)
        print(aa)
